<template>
	<view class="container">
		<view class="header">
			<view class="header-top">
				<text :class="{active: active == 1}" @click="headerTop(1)">今天</text>
				<text :class="{active: active == 2}" @click="headerTop(2)">昨日</text>
				<text :class="{active: active == 3}" @click="headerTop(3)">本周</text>
				<text :class="{active: active == 4}" @click="headerTop(4)">本月</text>
				<text :class="{active: active == 5}" @click="headerTop(5)">上月</text>
				<text :class="{active: active == 6}" @click="headerTop(6)">本年</text>
				<text :class="{active: active == 7}" @click="headerTop(7)">上年</text>
			</view>
			<view class="header-bottom">
				<view class="header-bottom-item">
					<text class="header-bottom-title">
						付款笔数
					</text>
					<view>0</view>
				</view>
				<view class="header-bottom-item">
					<text class="header-bottom-title">
						成交金额
					</text>
					<view>0</view>
				</view>
				<view class="header-bottom-item">
					<text class="header-bottom-title">
						预估收益
					</text>
					<view>0</view>
				</view>
			</view>
		</view>
		
		<view class="main">
			<view class="main-nav">
				<text>日期</text>
				<text>付款笔数</text>
				<text>成交金额</text>
				<text>预估收益</text>
				<text>查看</text>
			</view>
			<view class="main-content">
				
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data(){
			return {
				active: 1
			}
		},
		methods: {
			headerTop(value){
				this.active = value
			}
		}
	}
</script>

<style lang="scss" scoped>
	.container{
		height: 100vh;
		font-size: 26rpx;
		background-color: #f1f1f1;
		box-sizing: border-box;
		.header{
			background: #fff;
			.header-top{
				padding: 30rpx 0rpx;
				text-align: center;
				border-bottom: 1px solid #ccc;
				font-size: 30rpx;
				text{
					display: inline-block;
					padding: 0 20rpx;
					&.active{
						color: red;
					}
				}
			}
			.header-bottom{
				display: flex;
				padding-top: 40rpx;
				.header-bottom-item{
					flex: 1;
					text-align: center;
					.header-bottom-title{
						font-size: 24rpx;
						color: #626c6e;
					}
					>view{
						height: 120rpx;
						line-height: 120rpx;
						font-size: 38rpx;
					}
				}
			}
		}
		
		.main{
			background-color: #fff;
			margin-top: 30rpx;
			.main-nav{
				display: flex;
				font-size: 28rpx;
				padding: 30rpx 0;
				border-bottom: 1px solid #ccc;
				text{
					flex: 1;
					text-align: center;
					color: #626c6e;
				}
			}
			.main-content{
				height: 400rpx;
			}
		}
	}
</style>